package
{
	import alternativa.engine3d.core.Mesh;
	import alternativa.engine3d.materials.FillMaterial;
	
	public class Cadre extends Mesh
	{
		protected var hauteur:int;
        protected var Larg:int;
        protected var Long:int;
		
		public function Cadre(lo:Number,la:Number,h:Number)
		{
			super("Cadre");
			hauteur = h;
            Larg = la;
            Long = lo;
				      
	        createVertex(0,0,0,9);
	        createVertex(0,0,hauteur,10);
	        createVertex(Long,0,0,11);
	        createVertex(Long,0,hauteur,12);    
	        createVertex(Long,Larg,0,13);
	        createVertex(Long,Larg,hauteur,14);
	        createVertex(0,Larg,0,15);
	        createVertex(0,Larg,hauteur,16);
			
			createFace([16,10,9,15],"Flc");//left
	        createFace([13,11,12,14],"Frc");//right
	        createFace([14,12,10,16],"Ftc");//top
	        createFace([15,9,11,13],"Fsc");//sol
			
			createSurface(["Flc","Frc","Ftc","Fsc"],"cadre");	
	        setMaterialToSurface(new FillMaterial(0xa4a496,1,"normal",0.1,0xa4a496),"cadre");
		}

	}
}